
import './App.css';
import React, { Component } from 'react'
import Hello from './components/Hello/Hello'
import Welcome from './components/Welcome/Welcome'
import { Route, Redirect } from 'react-router-dom'
import About from './components/About'
import Home from './components/Home'
import MyLink from './components/MyNavLink'
class App extends Component {
  render() {
    return (
      <div>

        <Hello />
        <Welcome />

        {/* <NavLink to="/home" activeClassName="active">点击跳转到Home页</NavLink> <br />
        <NavLink to="/about" activeClassName="active">点击跳转到About页</NavLink> <br /> */}
        <MyLink to="/home">Home</MyLink>
        <MyLink to="/about">About</MyLink>
        <Route path="/about" component={About} />
        <Route path="/home" component={Home} />
        <Redirect to="/home" />
      </div>
    )
  }
}

export default App;
